-- GENERATED SPELL FOR [Dragonflayer Handler] --


function spell0_23871(pUnit, Event) --@Cleave,n/a--
pUnit:FullCastSpellOnTarget(15496,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_23871', 577, 1)
end

function spell1_23871(pUnit, Event) --@Net,n/a--
pUnit:FullCastSpellOnTarget(6533,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_23871', 2259, 1)
end

function Sorts_23871(pUnit, Event)
local choix_sorts_23871 = math.random(0, 1)
if choix_sorts_23871 == 0 then
pUnit:RegisterEvent('spell0_23871', 1, 1)
end
if choix_sorts_23871 == 1 then
pUnit:RegisterEvent('spell1_23871', 1, 1)
end
end

function mob23871_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_23871', math.random(1500, 3000), 1)
end

function mob23871_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob23871_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob23871_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(23871, 1, 'mob23871_Action')
RegisterUnitEvent(23871, 2, 'mob23871_Leave')
RegisterUnitEvent(23871, 3, 'mob23871_Kill')
RegisterUnitEvent(23871, 4, 'mob23871_Die')
